package com.ztgf.shopping.models.service.shop;

import com.baomidou.mybatisplus.service.IService;
import com.ztgf.common.constant.Result;
import com.ztgf.shopping.models.bo.shop.CorpAuthInfoBO;
import com.ztgf.shopping.models.bo.shop.ShopQiyuesuoAuthCallBackInfoBO;
import com.ztgf.shopping.models.bo.shop.ShopQiyuesuoAuthStateInfoBO;
import com.ztgf.shopping.models.bo.shop.ShopQiyuesuoInfoSaveBO;
import com.ztgf.shopping.models.dto.shop.ShopQiyuesuoInfoDTO;

import java.io.FileNotFoundException;
import java.util.List;

/**
 * 契约锁店铺信息服务
 *
 * @author YUE
 * @Date 2020-06-15 16:18:38
 */
public interface IShopQiyuesuoInfoService extends IService<ShopQiyuesuoInfoDTO> {
    boolean add(ShopQiyuesuoInfoSaveBO saveBO);

    String getContractString(Long contractId);

    String getSignaturePage(Long ShopId, Long contractId, int type, String orderIds, int signType);

    String promoteContract(Long jiaShopId, Long yiShopId, Long orderId, String param, byte[] bytes,String affix);

    boolean cancelContact(Long contractId, Integer contactState);

    boolean getSignContactState(Long contractId, int type);

    Result getEnterpriseAuthenticationStr(ShopQiyuesuoInfoDTO shopQiyuesuoInfoDTO) throws FileNotFoundException;

    ShopQiyuesuoAuthStateInfoBO getByQiyuesuoState(Long shopId);

    ShopQiyuesuoInfoDTO getByCompanyName(String companyName);

    boolean updateByCallBackInfo(ShopQiyuesuoAuthCallBackInfoBO shopQiyuesuoAuthCallBackInfoBO);

    CorpAuthInfoBO getEnterpriseAuthenticationState(String companyName);

    List<ShopQiyuesuoInfoDTO> getListAuthenticationing();

    String updateContactByCallBackInfo(String signature, String timestamp, String content) throws Exception;

    boolean getPassStatusByShopId(Long shopId);

    String getAbandonSignaturePage(Long ShopId, Long contractId, int signType);

    boolean updatePhoneById(ShopQiyuesuoInfoDTO bo);

    /**
     * 校验验证码并修改手机号
     * @param shopId
     * @return
     */
    boolean CheckPhone(Long shopId,String captcha,String newCaptcha,String mobile,String newMobile);
}
